<%@page import="member.MemberVo"%>
<%@page import="java.util.ArrayList"%>
<%@page import="member.MemberMyba"%>
<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>List(회원)</title>
<script>
function insert(){
	location.href="insert.jsp";
}
</script>
</head>
<body>
<!-- jsp:useBean 과 jsp:setProperty 는 form 데이터의 값을 주기적으로 주기 위해서 필요한 필요한 영역 -->
<jsp:useBean id="memberVo" class="member.MemberVo"/>
<jsp:setProperty property="*" name="memberVo"/>
<%
MemberMyba member = new MemberMyba();
member.setMemberVo(memberVo);
ArrayList<MemberVo> data = member.list();
%>
<input type="button" value="입력" onclick="insert()">
<form name="member_List" method="post" action="list.jsp">
	<input type="search" name="find" value="<%=memberVo.getFind()%>">
	<input type="submit" value="검색">
</form>
<hr/>

<%
for(int i=0; i<data.size(); i++){
	MemberVo v = data.get(i);
	out.print("<div>");
	out.print("<a href='view.jsp?memberid=" + v.getMemberid() + "'> " + v.getMemberid() + "</a>, " + v.getIrum());
	
	out.print("</div>");
}
%>




</body>
</html>